<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      .box {
        width: 5px;
        height: 5px;
        background: red;
				/* 默认从0% offset-distance 开始 */
        offset-path: path("M10,10 L20,50 L40,10 L60,50 L70,10");
        animation: move 3s linear infinite;
      }
      @keyframes move {
        100% {
          offset-distance: 100%;
        }
      }
    </style>
  </head>
  <body>
    <div class="box"></div>
    <svg xmlns="http://www.w3.org/2000/svg" version="1.1">
      <path d="M10,10 L20,50 L40,10 L60,50 L70,10" stroke="green" stroke-width="1" fill="none" />
    </svg>
  </body>
</html>

